home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1999 March / EnigmA AMIGA RUN 35 (1999)(G.R. Edizioni)(IT)[!][issue 1999-03].iso / earcd / devel / vbcc-68k-src / machines / amiga68k / libsrc / extra / getch.c < prev    next >
C/C++ Source or Header  |  1999-01-01  |  363b  |  18 lines

  1. /*  Very simple implementation of getch for vbcc - use at own risk! */
  2. /*  Strange things may happen (or not) if stdin is not tty or getch */
  3. /*  is mixed with buffered io.                                      */
  4.  
  5. #include <stdio.h>
  6.  
  7. int getch()
  8. {
  9.     int k;
  10.     SetMode(stdin->filehandle,1);
  11.     k=getchar();
  12.     SetMode(stdin->filehandle,0);
  13.     return k;
  14. }
  15.  
  16.  
  17.  
  18.